<div class="layui-container">

    <div>
        <h3>{$item.name}</h3>
        <p>{$item.createTime}更新</p>

    </div>

    <style>
        #carousel img{
            width: 100%;
            height: 100%;
        }
        .iteminfo{
            margin: 50px;
        }

        .iteminfo td,.iteminfo tr {
            padding: 10px;
            /*border: 1px solid ;*/
        }

    </style>
    <div class="layui-row">
        <div class="layui-col-md3">
            <div class="layui-carousel" id="carousel">
                <div carousel-item >
                    {if $item.pic1} <div><img src="__UPLOAD__/{$item.pic1}" alt=""></div>{/if}
                    {if $item.pic2} <div><img src="__UPLOAD__/{$item.pic2}" alt=""></div>{/if}
                    {if $item.pic3} <div><img src="__UPLOAD__/{$item.pic3}" alt=""></div>{/if}


                </div>

            </div>

        </div>

        <div class="layui-col-md6">
            <table class="iteminfo">
                <tr>
                    <td>价格</td>
                    <td>{$item.price}￥</td>
                </tr>
                <tr>
                    <td>成色</td>
                    <td>{$item.conditions.name}</td>
                </tr>
                <tr>
                    <td>联系人</td>
                    <td>{$item.user.username}</td>
                </tr>
                <tr>
                    <td >联系电话</td>
                    <td>{$item.user.phone}</td>
                </tr>
            </table>
        </div>

        <div class="layui-col-md3">
            <table class="layui-table">
                <tr>
                    <td></td>
                    <td><img src="__UPLOAD__/{$item.user.avatar}" alt=""></td>
                </tr>
                <tr>
                    <td>注册时间</td>
                    <td>{$item.user.regtime}</td>
                </tr>
                <tr>
                    <td>昵称</td>
                    <td>{$item.user.username}</td>
                </tr>
                <tr>
                    <td>手机</td>
                    <td>{$item.user.phone}</td>
                </tr>

            </table>
        </div>

    </div>
    <div class="layui-row">
        <div class="layui-tab">
            <ul class="layui-tab-title">
                <li class="layui-this">详细介绍</li>
<!--                <li>相关推荐</li>-->
            </ul>
            <div class="layui-tab-content">
                <div class="layui-tab-item layui-show">
                    <h1>文字介绍</h1>
                    <div>{$item.info}</div>
                </div>
                <div class="layui-tab-item">
                    相关推荐
                </div>
            </div>
        </div>


    </div>
    <style>
        .imgbox {
            /*float: left;*/


        }
        .imgbox img{
            float: left;
            width: 300px;
            margin: 10px;

        }
    </style>

    <div class="layui-row">
            <h1>图片展示</h1>
        <div class="imgbox">
        {if $item.pic1} <img src="__UPLOAD__/{$item.pic1}" alt="">{/if}
        {if $item.pic2} <img src="__UPLOAD__/{$item.pic2}" alt="">{/if}
        {if $item.pic3} <img src="__UPLOAD__/{$item.pic3}" alt="">{/if}
        </div>

    </div>

    <div>
        <h1>留言板</h1>
        <textarea class="layui-textarea"></textarea>
        <input type="submit" class="layui-btn">

    </div>

    <div class="layui-row">
        <div id="messagebroad" style="margin-top: 50px;">
            <h3>留言内容</h3>
            <div >
                <img style="width: 50px;" src="__UPLOAD__/{$item.user.avatar}" alt="">{$item.user.username}
                <p>价格已经很便宜了，需要直接拍</p>
                <a href="">回复</a>
                <a href="">举报</a>
                <hr>

            </div>

            <div >
                <img style="width: 50px;" src="__UPLOAD__/{$item.user.avatar}" alt="">{$item.user.username}
                <p>屠龙刀别来</p>
                <a href="">回复</a>
                <a href="">举报</a>
                <hr>

            </div>
        </div>

    </div>
</div>




<script>
    layui.use('carousel', function(){
        var carousel = layui.carousel;
        //建造实例
        carousel.render({
            elem: '#carousel'
            ,width: '100%' //设置容器宽度
            ,arrow: 'always' //始终显示箭头
            //,anim: 'updown' //切换动画方式
        });
    });
</script>
<script>
    //注意：选项卡 依赖 element 模块，否则无法进行功能性操作
    layui.use('element', function(){
        var element = layui.element;

        //…
    });


</script>
